#ifndef COLORWIDGET_H
#define COLORWIDGET_H

#include <QWidget>
#include "global.h"

namespace Ui {
class ColorWidget;
}

class ColorWidget : public QWidget
{
    Q_OBJECT

public:
    explicit ColorWidget(QWidget *parent = nullptr);
    ~ColorWidget();

    QColor GetColor();

    unsigned short Size = 3;

    unsigned short GetSize();

    bool isSelectNitePen = false;

protected:
    void initUI();

protected slots:
    void onClickedBlackColor();
    void onClickedWhiteColor();
    void onClickedBlueColor();
    void onClickedGreenColor();
    void onClickedYellowColor();
    void onClickedOrangleColor();
    void onClickedRedColor();
    void onClickedPurpleColor();

    void onButtonSize1Clicked();
    void onButtonSize2Clicked();
    void onButtonSize3Clicked();
    void onButtonSize4Clicked();

signals:
    void changeColor();

    void changeSize();

private:
    Ui::ColorWidget *ui;

    QColor color;
};

#endif // COLORWIDGET_H
